package com.itbaiwei.testday01.day01.annotation;

import java.util.Timer;

/**
 * Class: Main7
 * Description:
 * Author: haijun.xu
 * Date: 2025/4/25 15:45
 */

enum MyRetentionPolicy1{
    SOURCE,
    CLASS,
    RUNTIME;
    public String getChineseName(){
        switch (this){
            case SOURCE:
                return "源码中";
            case RUNTIME:
                return "运行时间";
            case CLASS:
                return "在class文件";
            default:
                return "不合法";
        }
    }
}
public class Main7 {
    public static void main(String[] args) {
        MyRetentionPolicy1 runtime = MyRetentionPolicy1.RUNTIME;
        String chineseName = runtime.getChineseName();
        System.out.println(chineseName);

        Timer timer;


    }
}
